package com.liang.serviceImpl;

import java.util.List;
import java.util.Map;
import java.util.Set;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.liang.dao.RoleDao;
import com.liang.pojo.Gorillaceo;
import com.liang.pojo.Role;
import com.liang.service.RoleService;
@Service
public class RoleServiceImpl implements RoleService{
	@Autowired
	RoleDao roleDao;
	public int insertRole(Role role) {
		return roleDao.insertRole(role);
	}
	public int deleteRoleById(int id) {
		return roleDao.deleteRoleById(id);
	}
	public List<Role> selectAllRole(Map<String, Object> map) {
		return roleDao.selectAllRole(map);
	}
	public Role selectRoleById(int id) {
		return roleDao.selectRoleById(id);
	}
	public int updateRole(Role role) {
		return roleDao.updateRole(role);
	}
	public int deleteRoleByList(Gorillaceo gorillaceo) {
		return roleDao.deleteRoleByList(gorillaceo);
	}
	@Override
	public List<Role> selectAllRoleByUsername(String username) {
		return roleDao.selectAllRoleByUsername(username);
	}
	
}
